Learn R Programming

reutils (version 0.2.1)

[,efetch,character,missing-method: EFetch accessors

Description

Extract XML nodes from an efetch object.

Usage

## S3 method for class 'efetch,character,missing':
[(x, i, j)

## S3 method for class 'efetch,character': [[(x, i)

Arguments

x
An efetch object containing XML data.
i
An XPath expression specifying the XML nodes to extract.
j
Ignored.

Value

  • An XML node set.

Examples

Run this code
p <- efetch("195055", "protein", "gp", "xml")
p['//GBFeature[GBFeature_key="mat_peptide"]//GBQualifier_value']

Run the code above in your browser using DataLab